package shuai.dao;

import java.util.List;

import org.springframework.jdbc.core.support.JdbcDaoSupport;

public class UserSupportDao extends JdbcDaoSupport implements UserDao {

	public List<User> search() {
		
		return null;
	}

	public List<User> search(User user) {
		
		return null;
	}

	public User findById(int Userno) {
		
		return null;
	}

	public void save(User user) {
		String sql="insert into t_user(username,password,age) values(?,?,?)";
		Object[] params={user.getUsername(),user.getPassword(),user.getAge()};
		//继承的JdbcDaoSupport类中有getJdbcTemplate方法
		getJdbcTemplate().update(sql,params);

	}

	public void update(User user) {
		

	}

	public void delete(int userno) {
		

	}

}
